feat: Add Modular Pipeline for Stable Diffusion 3 (SD3)#13324
feat: Add Modular Pipeline for Stable Diffusion 3 (SD3)#13324AlanPonnachan wants to merge 26 commits intohuggingface:mainfrom
Conversation
|
@AlanPonnachan thanks for this PR! Could you also provide some test code and sample outputs? |
sayakpaul
left a comment
There was a problem hiding this comment.
Thanks for getting started on this! I left some comments (majorly on the use of guidance).
|
@claude can you review this? |
|
I'll analyze this and get back to you. |
|
@bot /style |
|
Style bot fixed some files and pushed the changes. |
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
|
@sayakpaul Sample outputs you can find here: #13324 (comment) |
yiyixuxu
left a comment
There was a problem hiding this comment.
thanks for working on this!
I left one comment
- add autodocstring to assembled blocks
| logger = logging.get_logger(__name__) | ||
|
|
||
|
|
||
| # auto_docstring |
There was a problem hiding this comment.
i added a doc page on this here #13382
basically you need to run
python utils/modular_auto_docstring.py --fix_and_overwrite
and to look through the generated docstring to see if all the paramters are properly defined
There was a problem hiding this comment.
@yiyixuxu , I added description to most of InputParam and OutputParam and ran the above script.
I skimmed throught the docstrings once and felt right .
Let me know your thoughts!
|
@claude |
|
I'll analyze this and get back to you. |
yiyixuxu
left a comment
There was a problem hiding this comment.
thanks, i left some comments
Create .ai/modular.md as a shared reference for modular pipeline conventions, patterns, and common mistakes — parallel to the existing models.md for model conventions. Consolidates content from the former modular-conversion.md skill file and adds gotchas identified from reviewing recent modular pipeline PRs (LTX #13378, SD3 #13324). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2. refactored encoders and inputs 3. refactored for more flat structure 4. styling
|
@bot /style |
|
Style bot fixed some files and pushed the changes. |
|
can you look into the CI failures? |
|
@claude could you review the PR? |
|
Claude finished @sayakpaul's task in 3m 30s —— View job Review of SD3 Modular Pipeline
Overall the structure follows the modular pipeline conventions well — the flat block layout requested by @yiyixuxu is in place, That said, I found several issues that should be addressed before merge: Issue 1 (High):
|

What does this PR do?
This PR introduces the modular architecture for Stable Diffusion 3 (SD3), implementing both Text-to-Image (T2I) and Image-to-Image (I2I) pipelines.
Key additions:
SD3ModularPipelineandSD3AutoBlocksto the dynamic modular pipeline resolver.BlockStateTestSD3ModularPipelineFastandTestSD3Img2ImgModularPipelineFasttest suites.Related issue: #13295
Before submitting
documentation guidelines, and
here are tips on formatting docstrings.
Usage Example
Colab notebook: https://colab.research.google.com/drive/18_tZWIQdObq8EX0Vyd9ysGA-oACDwpf8?usp=sharing
Outputs
Text-to-Image:
Image-to-Image:
Who can review?
@sayakpaul @asomoza